import {reqUserLogin} from '@/api/index'

const state={}
const mutations={}
const actions={
        async Login({commit},data){
        let result = await reqUserLogin(data)
        if(result.code===200){
            window.localStorage.setItem('token',result.data);
        }else{
            alert('账号或密码错误');
        }
    }
}

export default {
    state,
    mutations,
    actions
}